package com.tyk.bookstore.front.product.model.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.math.BigDecimal;

/**
 * @author tyk
 * @description 书籍统计信息
 */
@Schema(name = "BookStatisticDo", description = "书籍统计信息")
@Data
@TableName("book_statistic")
public class BookStatisticDo implements Serializable{

    @Serial
    private static final long serialVersionUID = 1L;


    @Schema(description = "书籍")
    @TableId(value = "book_id")
    private Long bookId;

    @Schema(description = "收藏人数")
    @TableField("collect_num")
    private Long collectNum;

    @Schema(description = "支付人数")
    @TableField("pay_num")
    private Long payNum;

    @Schema(description = "评论人数")
    @TableField("comment_num")
    private Long commentNum;

    @Schema(description = "销量")
    @TableField("sale_num")
    private Long saleNum;

    @Schema(description = "点赞人数")
    @TableField("like_num")
    private Long likeNum;

    @Schema(description = "价格(冗余)")
    @TableField("price")
    private BigDecimal price;

}
